﻿@{ 
    Layout = null; 
}
@using MvcSiteMapProvider.Web.Html
@using MvcSiteMapProvider.Web.Html.Models
@using SRF.UI.Html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>@Html.AppTitle()</title>
    @Styles.Render("~/Content/style.css")
    @Scripts.Render("~/Scripts/jquery.min.js", "~/Scripts/bootstrap/js/bootstrap.min.js","~/Scripts/common.js")
    <script language="javascript" type="text/javascript"> 

        $(function () {
            $(".subnav-title").on("click", function () {
                var $icon = $(this).find("i");
                if ($(this).next().css("display") == "none") {
                    $icon.attr("class", "icon-chevron-down");
                } else {
                    $icon.attr("class", "icon-chevron-right");
                };
                $(this).next().slideToggle("fast", "linear");
            })
        })
        function openUserProfile() {
            //新增\修改
            $.dialog({
                url: "/admin/user/UserProfile",
                title: "配置",
                height: 400,
                width: 600,
                buttons:{
                    "关闭": {
                        "class": "btn",
                        "data-dismiss": 'modal'
                    }
                },
                callback: function (returnValue) {
                    location.reload();
                },
                loading: function () {
                    $(this).iframeLoading();
                }
            });
        }

    </script> 
    @RenderSection("header", false)
</head>
<body class="mainbody">
    <div id="header">
        <div id="logo">
        </div>
        @Html.MvcSiteMap().Menu(false)
        @if (SRF.Security.SecurityContext.IsLogin)
        {
            <div class="userinfo">
                <div class="dropdown">
                    <a class='dropdown-toggle' data-toggle="dropdown" style="padding-right: 15px; cursor: pointer">
                        @SRF.Security.SecurityContext.User.UserName <b class="caret"></b></a>
                    <ul class="dropdown-menu pull-right">
                        <li><a href="javascript:openUserProfile();">配置</a></li>
                        <li><a href="/logout">退出</a></li>
                    </ul>
                </div>
            </div>
        }
    </div>
    <div id="sidebar">
        @Html.MvcSiteMap().SiteMap()
    </div>
    <div id="content">
        <div id="main" class="container-fluid">
            <div class="row-fluid row-heighter">
                <div id="breadcrumb" class="span4">
                    <span>@Html.PageTitle()</span><span class="text-info">@ViewData["message"]</span></div>
                <div class="span8">
                    @RenderSection("toolbar", false)
                </div>
            </div>
            @RenderBody()
        </div>
        <div id="footer">
            Copyright ©2013 <a href="http://www.cnblogs.com/zengyy" target="_blank">zengyy</a></div>
    </div>
</body>
</html>
